/*
 * =====================================================================================
 *
 *       Filename:  feedbackWindow.h
 *
 *        Version:  1.3
 *        Created:  09/11/13 12:50:50
 *
 *         Author:  LIU RENSHENG (A0105649B), roastedbill@gmail.com
 *   Organization:  NUS, SoC
 *
 * =====================================================================================
 */

/**************************************************************************
 *          This Library describe a child window for our GUI              *
 *            It gives feedback for user input instructions               * 
 **************************************************************************/

#ifndef FEEDBACKWINDOW_H
#define FEEDBACKWINDOW_H

#include <QtCore/QTextStream>
#include <QtWidgets/QMainWindow>
#include <QKeyEvent>
#include "ui_feedbackWindow.h"

//@author A0105649B
// Define Style sheet string
const QString    feedBckWidgetStyle = "QWidget#feedBack {background:transparent;}";

class feedbackWindow : public QWidget //@ A0105649B
{
	Q_OBJECT

public:
	feedbackWindow     (QString feedBack, QPoint, QPoint, QWidget *parent = 0);
	~feedbackWindow    ();

private:
	// Component
	Ui::feedbackWindow ui;        

	// Mouse position
	QPoint       windowPos;
	QPoint       mousePos;
	QPoint       dPos;

	// Quit dialog whenever keyboard pressed
	void         keyPressEvent     (QKeyEvent*);
	
	// Display Style Configration
	void         changeDialogStyle (QPoint, QPoint);

	// Dragging window
	void         mousePressEvent   (QMouseEvent *);
	void         mouseMoveEvent    (QMouseEvent *);
};


#endif
